package digramas;

import java.awt.BorderLayout;
import java.awt.Toolkit;

import javax.swing.ImageIcon;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JScrollPane;
import javax.swing.SwingUtilities;
import javax.swing.UIManager;

//VS4E -- DO NOT REMOVE THIS LINE!
public class DiagramaInterfazG extends JFrame {

	private static final long serialVersionUID = 1L;
	private static final String PREFERRED_LOOK_AND_FEEL = "com.sun.java.swing.plaf.windows.WindowsLookAndFeel";;
	private JLabel jLabel0;
	private JScrollPane jScrollPane0;
	public DiagramaInterfazG() {
		initComponents();
	}

	private void initComponents() {
		add(getJScrollPane0(), BorderLayout.CENTER);
		setSize(800, 600);
	}

	private JScrollPane getJScrollPane0() {
		if (jScrollPane0 == null) {
			jScrollPane0 = new JScrollPane();
			jScrollPane0.setViewportView(getJLabel0());
		}
		return jScrollPane0;
	}

	private JLabel getJLabel0() {
		if (jLabel0 == null) {
			jLabel0 = new JLabel();
			jLabel0.setIcon(new ImageIcon(getClass().getResource("/digramas/Diagrama de Clases de la Intefaz.png")));
		}
		return jLabel0;
	}

	@SuppressWarnings("unused")
	private static void installLnF() {
		try {
			String lnfClassname = PREFERRED_LOOK_AND_FEEL;
			if (lnfClassname == null)
				lnfClassname = UIManager.getCrossPlatformLookAndFeelClassName();
			UIManager.setLookAndFeel(lnfClassname);
		} catch (Exception e) {
			System.err.println("Cannot install " + PREFERRED_LOOK_AND_FEEL
					+ " on this platform:" + e.getMessage());
		}
	}

	public static void run() {
		installLnF();
		SwingUtilities.invokeLater(new Runnable() {
			@Override
			public void run() {
				DiagramaInterfazG frame = new DiagramaInterfazG();
				frame.setDefaultCloseOperation(DiagramaInterfazG.EXIT_ON_CLOSE);
				frame.setTitle("Diagrama de Clases de la Intefaz");
				frame.getContentPane().setPreferredSize(frame.getSize());
				frame.pack();
				frame.setLocationRelativeTo(null);
				frame.setVisible(true);
				frame.setResizable(false);
				frame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
				frame.setIconImage (Toolkit.getDefaultToolkit().getImage(getClass().getResource("/images/diagrama.png")));
			}
		});
	}

}
